import request from '@/utils/request'

// 查询订单列表
export function getOrderList(query) {
  return request({
    url: '/trade/cargo/list',
    method: 'get',
    params: query
  })
}

// 查询订单详细
export function getDetail(orderId) {
  return request({
    url: '/trade/cargo',
    method: 'get',
    params: { orderId }
  })
}

// 新增订单管理
export function addOrder(data) {
  return request({
    url: '/trade/cargo',
    method: 'post',
    data: data
  })
}

//获取货物的运输信息
export function getCargoInfo(orderId){
  return request({
    url:'/trade/cargo/getCargoInfo',
    method:'get',
    params:{orderId}
  })
}
